Loading
Scriptbox
 VBScript Links 
 About VBscript 
 JavaScript Links 
 About JavaScript 
 Powershell Links 
 PSCRIPT the Script Launcher 
 PowerShell Shortcut Keys 
 About Powershell 
     VBScript
    JavaScript
    Powershell
Disclaimer
Contact
Latest 10 Scripts
Script search
  :: { Category } :: 0-9ABCDEFGHIJKLMNOPQRSTUVWXYZ
         

Search Options:  Modify  Terminal  Service  Audit  Permissions  

 Content of Modify Terminal Service Audit Permissions.vbs
MD5 Hash: BC8E819226786968A2E95278BE299859
' Description: Prevents the user fabrikam\bob from being able to query Terminal Services Accounting terminal for session information.


Const WINSTATION_QUERY = 0

strComputer = "."
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")

Set colItems = objWMIService.ExecQuery _
("Select * from Win32_TSAccount Where AccountName = 'fabrikam\\bob' AND " _
& "TerminalName = 'Accounting'")

For Each objItem in colItems
errResult = objItem.ModifyAuditPermissions(WINSTATION_QUERY, False)
ext

   © 2008 - 2013 Boris Toll      :: Scripts available: 6.481 ::      :: scriptbox.toll.at ::      :: powered by www.toll.at ::
  Google Entries:n/a
  Yahoo Backlinks:n/a
  Live Backlinks:n/a
  del.icio.us Bookmarks:n/a
  Technorati Links:n/a